#pragma once

#include "CoreMinimal.h"
#include "LRG_DebugComponent.generated.h"

UCLASS(Blueprintable, ClassGroup=(LineReplicationGraph), meta=(BlueprintSpawnableComponent))
class LINEREPLICATIONGRAPH_API ULRG_DebugComponent : public UActorComponent
{
	GENERATED_BODY()

protected:
	ULRG_DebugComponent(const FObjectInitializer& ObjectInitializer = FObjectInitializer::Get() );

	virtual void EndPlay(const EEndPlayReason::Type EndPlayReason) override;
	virtual void BeginPlay() override;
	virtual void GetLifetimeReplicatedProps(TArray<class FLifetimeProperty>& OutLifetimeProps) const override;
public:
	UFUNCTION(Client, Reliable)
	void EnableDebug(bool Value);

private:
	bool bEnableDebug = false;

public:
	UPROPERTY(Replicated)
	int32 CurrentGridCoordX;
	UPROPERTY(Replicated)
	int32 CurrentGridCoordY;
};